package com.itheima.Demo;

public class Demo01 {
    public static void main(String[] args) throws ClassNotFoundException {
        //类名调用class属性
        Class<AAA> c1 = AAA.class;
        System.out.println(c1);
        //使用对象调用getClass()方法
        AAA a = new AAA();
        Class<? extends AAA> c2 = a.getClass();
        System.out.println(c2);
        //使用Class的静态方法forName()
        Class<?> c3 = Class.forName("com.itheima.Demo.AAA");
        System.out.println(c3);
    }
}
